# -*- coding:utf-8 -*-

""" constants """
EMAIL = 'taballa+i@gmail.com'
EMAILTO = 'mailto:'+EMAIL
HOST='http://'+request.env.http_host


""" menu """
APPLICATION = request.application

MAIN = URL(r=request, a='main', c='default', f='index')
ITAOBAO = URL(r=request, a=APPLICATION, c='default', f='index')
PRODUCT = URL(r=request, a=APPLICATION, c='product', f='index')
SHOP = URL(r=request, a=APPLICATION, c='shop', f='index')
INFO = URL(r=request, a=APPLICATION, c='info', f='index')
TEST = URL(r=request, a=APPLICATION, c='test', f='index')
ADD = URL(r=request, a=APPLICATION, c='add', f='index')
AGREE = URL(r=request, a=APPLICATION, c='agree', f='index')
PROFESSION = URL(r=request, a=APPLICATION, c='profession', f='index')
STOCK = URL(r=request, a=APPLICATION, c='stock', f='index')

ERROR = URL(r=request,a='main',c='default',f='index')

response.menu = [
#    ['首页', False, MAIN],
    ['首页', False, ITAOBAO],
    ['店铺', False, SHOP],
    ['宝贝', False, PRODUCT],
    ['同行', False, PROFESSION],
    ['上货', False, STOCK],
    ['Info', False, INFO],
    ['Test', False, TEST],
    ['Add', False, ADD],
    ['Agree', False, AGREE],
    ]


""" title """
response.title = '爱淘宝'
if request.controller == 'default':
    response.title = '爱淘宝 -- 首页'
elif request.controller == 'shop':
    response.title = '爱淘宝 -- 店铺'


""" other """
APPLICATIONNAME = "爱淘宝"